﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Register.aspx.cs" Inherits="_0812159_0812164.Register" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Register</title>
    <link type="text/css" rel="stylesheet" href="style.css" />
</head>
<script type="text/javascript" language="javascript">
    function check_frm_login()
    {
        if(document.frmlogin.txtUsername.value.length==0)
        {
            alert("Bạn chưa nhập tên truy cập")
            document.frmlogin.txtUsername.focus()
            return false
        }
        if(document.frmlogin.txtPassword.value.length==0)
        {
            alert("Bạn chưa nhập mật khẩu")
            document.frmlogin.txtPassword.focus()
            return false
        }
        if(document.frmlogin.txtPassword.value != document.frmlogin.txtRepassword.value)
        {
            alert("Xác nhận mật khẩu sai")
            document.frmlogin.txtRepassword.focus()
            return false
        }
        
        return true;
    }   
</script>
<body>
<center>
<br />
<br />
<br />
<br />
<br />
<div id="frmregister">
    <form  id="frmlogin" runat="server" onsubmit="return check_frm_login()">
    
        <div class="capture">Đăng ký</div>
        <div>
            <table>
                <tr>
                    <td colspan="2">
                        <asp:Label ID="lblMessage" runat="server" Text=""></asp:Label></td>
                    </tr>
                <tr>
                    <td align="right">Username : </td>
                    <td><asp:TextBox class ="textbox" ID="txtUsername" runat="server"></asp:TextBox></td>
                </tr>
                <tr>
                    <td align="right">Password : </td>
                    <td><asp:TextBox class="textbox" ID="txtPassword" TextMode="Password" runat="server"></asp:TextBox></td>
                </tr>
                <tr>
                    <td align="right">Xác nhận Password : </td>
                    <td><asp:TextBox class ="textbox" ID="txtRepassword" TextMode="Password" runat="server"></asp:TextBox></td>
                </tr>
                <tr>
                    <td></td>
                    <td><asp:Button id="btnSubmit" class="button" runat="server" Text="Đăng ký" 
                            onclick="btnSubmit_Click"/></td>
                </tr>
            </table>
        </div>
    
    </form>
    </div>
    </center>
</body>
</html>
